package router

import (
	"gitee.com/ddlin/tiktok-go-tool/internal/handler"

	"gitee.com/ddlin/tiktok-go-tool/config"
	"github.com/gin-gonic/gin"
)

type Router struct {
	conf    config.Config
	engine  *gin.Engine
	toolSrv *handler.ToolSrv
}

func NewRouter(
	conf config.Config,
	engine *gin.Engine,
	toolSrv *handler.ToolSrv,
) *Router {
	return &Router{
		conf:    conf,
		engine:  engine,
		toolSrv: toolSrv,
	}
}

func (r *Router) Register() {
	base := r.engine.Group("/v1")
	base.POST("/tk/us/api", r.toolSrv.UsTransformTkApi)
}
